//
//  StatusNormalCell.swift
//  weibo-01
//
//  Created by 韩家奇 on 15/11/13.
//  Copyright © 2015年 hanjiaqi. All rights reserved.
//

import UIKit

class StatusNormalCell: StatusCell {
    override var viewModle: StatusViewModel? {
        didSet {
            pictureview.snp_updateConstraints { (make) -> Void in
                //根据配图数量,决定配图视图的顶部间距
                let offset  = viewModle?.thumbnailUrls?.count > 0 ? StatusCellMargin : 0
                make.top.equalTo(contentLabel.snp_bottom).offset(offset)
                
            }
        }
    }
   override func setupUI() {
        super.setupUI()
    // 3> 配图视图
    pictureview.snp_makeConstraints { (make) -> Void in
        make.top.equalTo(contentLabel.snp_bottom).offset(StatusCellMargin)
        make.left.equalTo(contentLabel.snp_left)
        make.width.equalTo(300)
        make.height.equalTo(90)
    }
    }

}
